<template>
  <div class="bridge"></div>
</template>

<script>
  import {login} from "@/assets/js/utils";
  import {systemConfig} from '@/assets/js/utils';//接口API
  var urlConfig = require('../config');
  export default {
    data() {
      return {};
    },

    components: {},

    computed: {},

    created() {
      login();
    },

    mounted() {
      let isMobile = {
        Windows: function () {
          return /IEMobile/i.test(navigator.userAgent);
        },
        Android: function () {
          return /Android/i.test(navigator.userAgent);
        },
        BlackBerry: function () {
          return /BlackBerry/i.test(navigator.userAgent);
        },
        iOS: function () {
          return /iPhone|iPad|iPod/i.test(navigator.userAgent);
        },
        any: function () {
          return (
            isMobile.Android() ||
            isMobile.BlackBerry() ||
            isMobile.iOS() ||
            isMobile.Windows()
          );
        }
      };
      systemConfig(config => {
        if (config.video_scheme == 'zego') {
          this.$router.push({path: '/3'});
        } else if (config.video_scheme == 'qiyiguo') {
          this.$router.push({path: '/4'});
        } else if (isMobile.iOS()) {
          this.$router.push({path: '/1'});
        } else if (isMobile.Android()) {
          this.$router.push({path: '/2'});
        }
      });
    },

    methods: {}
  };
</script>
<style lang='less' scoped>

</style>
